package com.chinaums.fsp.sdk.request;

import org.xiajinsuo.avro.specific.SpecificRecordBase;

import com.chinaums.fsp.base.pgt.TransType;
import com.chinaums.fsp.sdk.base.RequestData;
import com.chinaums.fsp.sdk.base.ResponseDataWrapper;
import com.chinaums.fsp.sdk.pgt.params.DraftEndorseRequest;
import com.chinaums.fsp.sdk.pgt.params.DraftEndorseResponse;
import com.chinaums.fsp.sdk.pgt.params.DraftStatusModifyRequest; 
/**
 * 汇票交易状态更新
 * @author hhh
 */
public class DraftStatusModifyTest extends BaseRequest{

	public void testDraftStatusModifyRequest1() throws Exception {
		
		PgtRequestFactory rf = FACTORY.factory();
		
		RequestData.Builder builder = this.createRequestDataBuilder();
		builder.setTransType(TransType.TRANSACTION_STATUS_MODIFY.getTransCode());
		
		DraftStatusModifyRequest data = DraftStatusModifyRequest.newBuilder()
															.setOrigServerTransId("1101012020041615323240549569")
															.setCheckStatus(1) // 0:待背书 1:待签收 2:待核验
															.build()
															;
		rf.transType(TransType.TRANSACTION_STATUS_MODIFY.getTransCode())
		.responseClass(SpecificRecordBase.class)
		.data(data)
		;
		ResponseDataWrapper rdw = rf.post();
	
		this.print(rdw);
	}
	
//	public void testDraftStatusModifyRequest2() throws Exception {
//		
//		PgtRequestFactory rf = FACTORY.factory();
//		
//		RequestData.Builder builder = this.createRequestDataBuilder();
//		builder.setTransType(TransType.TRANSACTION_STATUS_MODIFY.getTransCode());
//		
//		DraftStatusModifyRequest data = DraftStatusModifyRequest.newBuilder()
//															.setOrigClientTransId("20190620173632783418")
//															.setCheckStatus(2) // 0:待背书 1:待签收 2:待核验
//															.build()
//															;
//		rf.transType(TransType.TRANSACTION_STATUS_MODIFY.getTransCode())
//		.responseClass(SpecificRecordBase.class)
//		.data(data)
//		;
//		ResponseDataWrapper rdw = rf.post();
//		
//		this.print(rdw);
//	}
	
	
}